quartz: fix manual window move
authorRyan Lortie <desrt@desrt.ca>
Fri, 13 Dec 2013 01:18:01 +0000 (20:18 -0500)
committerRyan Lortie <desrt@desrt.ca>
Mon, 6 Jan 2014 20:27:28 +0000 (15:27 -0500)
We need to have gdk skip standard processing of events when we are in
manual move in addition to manual resize.

https://bugzilla.gnome.org/show_bug.cgi?id=720357

gdk/quartz/GdkQuartzNSWindow.c
gdk/quartz/GdkQuartzNSWindow.h
gdk/quartz/gdkevents-quartz.c

index b5eaae25e791d726a89618a22c2f807298dc7a8f..df96a260ed7705c321b3cf0bce9ba53100d4fe87 100644 (file)
   return YES;
 }
 
--(BOOL)isInManualResize
+/* Used by gdkevents-quartz.c to decide if our sendEvent() handler above
+ * will see the event or if it will be subjected to standard processing
+ * by GDK.
+*/
+-(BOOL)isInManualResizeOrMove
 {
-  return inManualResize;
+  return inManualResize || inManualMove;
 }
 
 -(void)beginManualMove
index da9ac58a79a4535adfd766e74dae34d0a5efa79f..e60232a91d672ab4f79b4f841080884fd05163e5 100644 (file)
@@ -37,7 +37,7 @@
 -(BOOL)isInMove;
 -(void)beginManualMove;
 -(BOOL)trackManualMove;
--(BOOL)isInManualResize;
+-(BOOL)isInManualResizeOrMove;
 -(void)beginManualResize;
 -(BOOL)trackManualResize;
 -(void)showAndMakeKey:(BOOL)makeKey;
index 6fddf433e8ca5915d908c5672571c78b02ebb5f9..d9fa4542560b5cebf829e76854f3dcd154fbcb98 100644 (file)
@@ -1360,10 +1360,10 @@ gdk_event_translate (GdkEvent *event,
       return FALSE;
     }
 
-  /* Also when in a manual resize, we ignore events so that these are
-   * pushed to GdkQuartzNSWindow's sendEvent handler.
+  /* Also when in a manual resize or move , we ignore events so that
+   * these are pushed to GdkQuartzNSWindow's sendEvent handler.
    */
-  if ([(GdkQuartzNSWindow *)nswindow isInManualResize])
+  if ([(GdkQuartzNSWindow *)nswindow isInManualResizeOrMove])
     return FALSE;
 
   /* Find the right GDK window to send the event to, taking grabs and